﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;

namespace DeliveryService
{
    /// <summary>
    /// 这是需要写的方法列表
    /// </summary>
    public interface IServiceNeedToDo
    {
        /// <summary>
        /// 根据餐馆名称搜索餐馆
        /// </summary>
        /// <param name="restaurantName">餐馆名称</param>
        /// <returns></returns>
        List<MRestaurant> GetRestaurantByName(string restaurantName);

        /// <summary>
        /// 根据商品名称搜索商品信息
        /// </summary>
        /// <param name="goodsName">商品名称</param>
        /// <returns></returns>
        List<MGoods> GetGoodsInforByGoodsName(string goodsName);

        /// <summary>
        /// 删除购物车
        /// </summary>
        /// <param name="studentId">学生ID</param>
        /// <param name="shoppingCartsIdList">购物车ID,以逗号分隔</param>
        /// <returns>true: 删除成功  false:删除失败</returns>
        bool DeleteShoppingCarts(int studentId, string shoppingCartsIdList);

        /// <summary>
        /// 更新购物车
        /// </summary>
        /// <param name="studentId">学生ID</param>
        /// <param name="shoppingCartsList">现在的购物车列表信息,JSON格式</param>
        /// <returns>true: 更新成功  false:更新失败</returns>
        bool UpdateShoppingCarts(int studentId, string shoppingCartsList);

    }
}